<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@page import="java.text.SimpleDateFormat"%>
<%@page import="com.crm.entity.Parts"%>
<%@page import="com.crm.dao.BusinessDAO"%>
<%@page import="com.crm.entity.Opportunity"%>
<%@page import="com.crm.entity.Business"%>
<%@page import="com.crm.entity.Executives"%>
<html xmlns="http://www.w3.org/1999/xhtml"><!-- InstanceBegin template="/Templates/temp.dwt" codeOutsideHTMLIsLocked="false" -->
<%@page import="com.crm.entity.Clientdet"%>
<%@ page language="java" import="java.sql.*,java.util.*"%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

<title>ASCRM</title>

<link href="<%=application.getContextPath()%>/css/css-crm.css" rel="stylesheet" type="text/css" />



<script type="text/javascript" src="<%=application.getContextPath()%>/js/jquery-1.7.2.min.js"></script>
<script language="javaScript" src="<%=application.getContextPath()%>/js/jquery-ui-1.8.20.custom.min.js"></script>

<script type="text/javascript" src="<%=application.getContextPath()%>/js/jquery-1.6.min.js"></script>	
<script type="text/javascript" src="<%=application.getContextPath()%>/js/jquery-ui-1.8.17.custom.min.js"></script>	
<script type="text/javascript" src="<%=application.getContextPath()%>/js/colResizable-1.3.min.js"></script>	
<link rel="stylesheet" href="<%=application.getContextPath()%>/css/jquery-ui-1.8.17.custom.css"/>


<style >
.ui-dialog {
	
	font-family: Arial, Helvetica, sans-serif;
	font-size: 12px;
	
}
</style>
	
</head>

<body>
<% Opportunity op=(Opportunity)request.getAttribute("opportunity"); %>
<div id="main">
  <div id="content"> 
    <div id="work-area2">
    
      <div class="heading">Enquiry </div>
	  
      <div class="boxIFS">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="366"><table width="1082" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="21">&nbsp;</td>
                <td width="152">&nbsp;</td>
                <td width="231">&nbsp;</td>
                <td width="68">&nbsp;</td>
                <td width="153">&nbsp;</td>
                <td width="457">&nbsp;</td>
                </tr>
              <tr>
                <td height="28">&nbsp;</td>
                <td align="left" valign="top">Organisation Name</td>
                <td align="left" valign="top"><%=op.getOrganisation() %></td>
                <td>&nbsp;</td>
                <td align="left" valign="top">Division</td>
                <td align="left" valign="top"><%=op.getDivision() %></td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Name Of User </td>
                <td align="left" valign="top"><%=op.getUser() %></td>
                <td>&nbsp;</td>
                <td align="left" valign="top">Enquiry Type </td>
                <td align="left" valign="top"><%=op.getEnquirytype() %></td>
              </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td>&nbsp;</td>
                <td align="left" valign="top">Bid Type </td>
                <td align="left" valign="top"><table width="70%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="19%"><% if(op.getTechnicalbid()==true){ %>
                          <input type="checkbox" name="techBid" value="technical Bid" checked="checked" />
                          <%} else {%>
                          <input type="checkbox" name="techBid" value="technical Bid"/>
                          <%} %>                      </td>
                      <td width="81%">Technical Bid </td>
                    </tr>
                    <tr>
                      <td height="5"></td>
                      <td height="5"></td>
                    </tr>
                    <tr>
                      <td><% if(op.getPricebid()==true) {%>
                          <input type="checkbox" name="priceBid" value="price Bid" checked="checked" />
                          <%} else{%>
                          <input type="checkbox" name="priceBid" value="price Bid"/>
                          <%} %>                      </td>
                      <td>Price Bid </td>
                    </tr>
                    <tr>
                      <td height="5"></td>
                      <td height="5"></td>
                    </tr>
                    <tr>
                      <td><%if(op.getWarranty()!=null){
                    if(op.getWarranty()==true) {%>
                          <input type="checkbox" name="warranty" value="warranty" checked="checked" />
                          <%} else{%>
                          <input type="checkbox" name="warranty" value="warranty"/>
                          <%} }%>                      </td>
                      <td>Warranty </td>
                    </tr>
                </table></td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Enquiry Number </td>
                <td align="left" valign="top"><%=op.getEnqnum() %></td>
                <td>&nbsp;</td>
                <td align="left" valign="top">Probability </td>
                <td align="left" valign="top"><%=op.getProbability() %></td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <%
                 java.sql.Date d=op.getDuedate();
				SimpleDateFormat sdf=new SimpleDateFormat("dd-MM-yyyy");
				String dat=sdf.format(d);
				
				
              %>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Due Date </td>
                <td align="left" valign="top"><div id="demo"><%=dat %></div></td>
                <td>&nbsp;</td>
                <td>Executive Name </td>
                <td><%= op.getExecName()%></td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Project Name </td>
                <td align="left" valign="top"><%=op.getProjName() %></td>
                <td>&nbsp;</td>
                <td>Quote Currency </td>
                <td><%=op.getCurencytype() %></td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Company</td>

          
                <td align="left" valign="top">

               <%Business bus=(Business)session.getAttribute("business"); %>
           <%=bus.getBusinessName() %>               </td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
              </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">Opportunity Name </td> 
                <td align="left" valign="top"><%=op.getEnquiryname() %></td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                </tr>
              <tr>
                <td height="5"></td>
                <td height="5" align="left" valign="top"></td>
                <td height="5" align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                <td align="left" valign="top"></td>
                </tr>
              
              <tr>
                <td>&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                <td align="left" valign="top">&nbsp;</td>
                </tr>
              
              <tr>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
                </tr>
            </table></td>
            </tr>
        </table>
      </div>
	  
	  <div class="boxtable">
	 
	  
	    <table width="100%" id="userTable" cellpadding="4" cellspacing="1" bgcolor="#C5E4EB">
          <tr>
          <td width="30" height="30" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"  style="background-repeat:repeat-x"></td>
            <td width="30" height="30" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"  style="background-repeat:repeat-x">S.No</td>
            <td width="100" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF"> Part No </td>
           <td width="160" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF">Description</td>
            <td width="120" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF">Make</td>
            <td width="60" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF"> Quantity </td>
            <td width="90" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF">Specification</td>
            <td width="90" align="left" valign="middle" background="<%=application.getContextPath()%>/images/table-box.jpg"   style="background-repeat:repeat-xbgcolor="#FFFFFF">Application</td>
          </tr>
           <% List<Parts> pr=(List<Parts>)request.getAttribute("parts");
           if(pr!=null){
        	   
           for(int j=0;j<pr.size();j++){
           %>
          <tr>
          	<td align="center" valign="middle" bgcolor="#FFFFFF"><input type="checkbox" name="chkbox"/></td>
            <td bgcolor="#FFFFFF"><%=j+1 %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getPrtnum() %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getDescription() %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getMake() %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getQty() %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getSpecification() %></td>
            <td align="left" valign="top" bgcolor="#FFFFFF"><%=pr.get(j).getApplication() %></td>
          </tr>
        <%
        }
           }%> 
        </table> 
	  </div>
    </div>
  </div><div id="footer"></div>  
</div>
</body>
</html>